<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script>
        window.onload = function(){
            document.getElementById('bt00').onclick = function(){
                var a = document.getElementById('baidu').innerHTML;
                a.onclick = function()
            }
        }
    </script>
</head>
<body>
    <a href="http://baidu.com" id="baidu">百度</a>
    <button id="bt00">点击访问</button>
</body>
</html>